package org.com.pojo;

import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;

/**
 * (Transactions)实体类
 *
 * @author makejava
 * @since 2025-03-04 20:23:25
 */
@TableName("transactions")
public class Transactions implements Serializable {
    private static final long serialVersionUID = -98919484552346829L;
/**
     * 唯一交易ID
     */
    @TableId
    private Integer id;
/**
     * 关联用户余额表的主键
     */
    private Long balanceId;
/**
     * 用户ID（需提前存在用户表）
     */
    private Integer userId;
/**
     * 金额变动（正数+，负数-）
     */
    private BigDecimal delta;
/**
     * 状态0是充值，1是充值,3是支出
     */
    private Integer status;
/**
     * 交易时间
     */
    private Date createdAt;


    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public Long getBalanceId() {
        return balanceId;
    }

    public void setBalanceId(Long balanceId) {
        this.balanceId = balanceId;
    }

    public Integer getUserId() {
        return userId;
    }

    public void setUserId(Integer userId) {
        this.userId = userId;
    }

    public BigDecimal getDelta() {
        return delta;
    }

    public void setDelta(BigDecimal delta) {
        this.delta = delta;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public Date getCreatedAt() {
        return createdAt;
    }

    public void setCreatedAt(Date createdAt) {
        this.createdAt = createdAt;
    }

}

